package com.chucang.shucang.ttp.paycenter.bo;

import cn.hutool.core.text.CharSequenceUtil;
import com.chucang.shucang.ttp.paycenter.constant.HFConstants;
import lombok.Data;

import java.io.Serializable;

/**
 * @author flitsneak
 * @email flitsneak@gmail.com
 * @date 2022/10/13 17:48
 * @description
 */
@Data
public class CFCAInfoBO implements Serializable {
    /**
     * 加签证书
     */
    private String pfxFile;
    /**
     * 加签密码
     */
    private String pfxFilePwd;
    /**
     * 解签证书
     */
    private String cerFile;
    /**
     * 汇付支付+编号
     */
    private String npayMerId;

    public String getNpayMerId() {
        if (CharSequenceUtil.isBlank(npayMerId)) {
            return HFConstants.NPAY_MERID;
        }
        return npayMerId;
    }

    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append("CfcaInfoBo [pfxFile=");
        sb.append(pfxFile);
        sb.append(",pfxFilePwd=");
        sb.append(pfxFilePwd);
        sb.append(",cerFile=");
        sb.append(cerFile);
        sb.append(",npayMerId=");
        sb.append(npayMerId);
        sb.append("]");
        return sb.toString();
    }
}
